<template>
  <el-scrollbar v-if="loading" :height="barHeight">
    <slot />
  </el-scrollbar>
  <el-skeleton v-else :rows="skeletonRow" animated />
</template>

<script setup lang="ts">
defineProps({
  barHeight: {
    type: String,
    default: '600px'
  },
  loading: {
    type: Boolean,
    default: true
  },
  skeletonRow: {
    type: Number,
    default: 8
  }
})
</script>

<style scoped lang="scss"></style>
